/* eslint valid-jsdoc: "off" */

/**
 * @param {Egg.EggAppInfo} appInfo app info
 */
module.exports = (appInfo) => {
  /**
   * built-in config
   * @type {Egg.EggAppConfig}
   **/
  const config = (exports = {});

  // use for cookie sign key, should change to your own and keep security
  config.keys = appInfo.name + "_1753929968554_2628";

  // add your middleware config here
  config.middleware = ["unifiedResponse"];

  // add your user config here
  const userConfig = {
    // myAppName: 'egg',
  };

  config.seleniumPool = {
    windowCount: 20, // 窗口数量
    idleTimeout: 1 * 60 * 1000, // 超时时间，1分钟
  };

  //启动参数
  config.cluster = {
    listen: {
      port: 7001,
      hostname: "0.0.0.0",
    },
  };

  //csrf
  config.security = {
    csrf: {
      enable: false,
    },
  };

  //chrome-driver的地址
  config.chromeDriver =
    "/www/wwwroot/tools/chromeDriver/chromedriver-linux64/chromedriver";
  config.env = "prod";
  return {
    ...config,
    ...userConfig,
  };
};
